import { postRequest, getRequest, upLoadRequest } from "./request";
// 推荐位
export const position = {
  content: {
    lists(data, fun) {
      return postRequest("/api/position.content/lists", data, false);
    },
    detail(data, fun) {
      return postRequest("/api/position.content/detail", data, false);
    }
  },
};
// 商品列表
export const product = {
  all(data, fun) {
    return postRequest("/api/product/all", data, false);
  }
};
// 保存配置
export const order = {
  submit(data, fun) {
    return postRequest("/api/order/submit", data, false);
  }
};
// 上传文件
export const upload = {
  file(data, fun) {
    return postRequest("/api/upload/file", data, false);
  }
};
// 登陆
export const staff = {
  login(data, fun) {
    return postRequest("/api/staff/login", data, false);
  },
  detail(data, fun) {
    return postRequest("/api/staff/detail", data, false);
  },
  checkToken(data, fun) {
    return postRequest("/api/staff/checkToken", data, false);
  }
};
export const user = {
  checkToken(data, fun) {
    return postRequest("/api/user/checkToken", data, false);
  }
};
// 验证码
export const common = {
  captcha(data, fun) {
    return postRequest("/api/common/captcha", data, false);
  }
};

